import pinia from '@/stores'
import {useUserstore} from "@/stores/userStore.ts";
export default {
    install(app:any){
        app.directive('has',{
           mounted(el:any,options : any){
               const userStore = useUserstore(pinia)
                if (!userStore.userInfo.buttons.includes(options.value)) {
                    el.parentNode.removeChild(el)
                }
            }
        })
    }
}